#!/bin/env python
#-*- coding:utf-8 -*-
'''


@author: Admin
'''
import wmi

conn = wmi.connect_server(server='127.0.0.1', namespace=r"root\virtualization\v2", user='administrator', password='123456', named_value_set='1111')
client = wmi.WMI(wmi=conn)
vms = client.query("select * from Msvm_ComputerSystem where Caption=\"Virtual Machine\"")
print vms

